← Back
Editing: index438.js
import{l as e,L as a,K as s,j as r}from"./utils-lib.js?v=1765440387";import{c as o,az as t,k as i,r as l,p as d,q as m,v as n,e as p,A as u,x as c,y as f,aa as w,a8 as _}from"./base-lib.js?v=1765440387";import{_ as b}from"./index135.js?v=1765440387";import{bb as j}from"./firewall.js?v=1765440387";import{f as v}from"./validator.js?v=1765440387";import{g as h}from"./useStore4.js?v=1765440387";import"./__commonjsHelpers__.js?v=1765440387";import"./index94.js?v=1765440387";import"./column.js?v=1765440387";const x={class:"ml-[10rem]"},g=o({__name:"index",setup(o,{expose:g}){const{refs:{isRefreshSpywares:y}}=h(),D=t("popupClose"),R=i({dirs:""}),V=l(),z=l(!1),E={dirs:[{validator:(e,a,s)=>{if(!(a.length>0))return s(new Error("请输入目录"));s()},trigger:["blur","change"]}]},S=[{content:"添加指定目录",event:()=>{v({type:"dir",change(e){""!=R.dirs?R.dirs=R.dirs+"\n"+e:R.dirs=e}})}},{content:"添加网站目录",event:()=>e({title:"添加网站目录",area:50,component:()=>a(()=>import("./add-website-dir.js?v=1765440387"),__vite__mapDeps([]),import.meta.url),compData:R,showFooter:!0})}];return d(()=>{}),g({onConfirm:async e=>{await V.value.validate(),s({request:j({data:JSON.stringify({dirs:R.dirs.split("\n")})}),loading:z,success:()=>{D(),y.value=!0}})}}),(e,a)=>{const s=r,o=w,t=b,i=_;return m(),n("div",null,[p(i,{disabled:c(z),ref_key:"addDir",ref:V,rules:E,model:c(R),class:"p-[2rem] addDirFrom overflow-auto max-h-[60rem]","label-width":"5rem"},{default:u(()=>[p(o,{label:"目录",prop:"dirs"},{default:u(()=>[p(s,{type:"textarea",modelValue:c(R).dirs,"onUpdate:modelValue":a[0]||(a[0]=e=>c(R).dirs=e),width:"30rem",class:"resize-none",autosize:{minRows:5,maxRows:5},placeholder:"如需填写多个目录请换行填写\n例:/www/aaa /www/bbb",clearable:""},null,8,["modelValue"])]),_:1}),p(o,null,{default:u(()=>[f("div",x,[p(t,{options:S})])]),_:1})]),_:1},8,["disabled","model"])])}}});export{g as default}; function __vite__mapDeps(indexes) { if (!__vite__mapDeps.viteFileDeps) { __vite__mapDeps.viteFileDeps = [] } return indexes.map((i) => __vite__mapDeps.viteFileDeps[i]) }
Save File
Cancel